<!DOCTYPE html>
<script src="../../resources/js-test.js"></script>
<script>
    addEventListener("load", function() {
        shouldBeTrue('document.getElementById("foo").clientWidth==75');
    }, false);
</script>
<div>This test passes if the image below looks like a 2x2 grid (yellow, gray, light green, dark green). In this case the srcset attribute has a base64 url, with the comma escaped.</div>
<div>The image is displayed in a width of 75px, since the 2x resource gets picked (as the highest density resource current available.</div>
<img id="foo" src=""
  srcset=" 2x,
           1x">
